
console.log ("Desk Calculator: operators are *, /, +, -, ^, () \n");
var expr = "2 + 3 * 4";          // need the spaces
var    token;

scanner = new Scanner ( expr );
error = new SlkError ( scanner );
action = new SlkAction ( scanner );

parse  ( action, scanner, error, 0 );

console.log ("=====================" );
console.log ("show_parse_derivation" );
console.log ("=====================" );
action.show_parse_derivation ();
console.log ("=====================" );
console.log ("show_tree" );
console.log ("=====================" );
action.show_tree ();
console.log ("=====================" );
console.log   ( expr +  " = " + action.get_answer() );

